package com.example.volleyball.playcharting.android;

import android.app.Activity;
import android.content.Intent;
import android.content.pm.ActivityInfo;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class MenuActivity extends Activity{
	Button newMatch;
	Button runAnalysis;
	Button instructButton;
	@Override
	public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);


        setContentView(R.layout.menu);

        
		final Intent playIntent = new Intent(this, MainActivity.class);

		//final Intent analysisIntent = new Intent(this, AnalysisActivity.class);
		 newMatch=(Button)findViewById(R.id.new_match);
	     newMatch.setOnClickListener(new OnClickListener(){
				@Override
				public void onClick(View v) {
					MenuActivity.this.startActivity(playIntent);
					
				}
	     });
	     
	     final Intent instructIntent = new Intent(this,InstructionsActivity.class);
	     instructButton = (Button)findViewById(R.id.instructions);
	     instructButton.setOnClickListener(new OnClickListener(){
	    	 public void onClick(View v){
	    		 MenuActivity.this.startActivity(instructIntent);
	    	 }
	     });
	     
	     final Intent analysisIntent = new Intent(this, AnalysisActivity.class);
	     runAnalysis = (Button)findViewById(R.id.run_analysis);
	     runAnalysis.setOnClickListener(new OnClickListener(){
	    	 public void onClick(View v){
	    		 MenuActivity.this.startActivity(analysisIntent);
	    	 }
	     });
		  
	 }

}
